home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Belgian Amiga Club - ADF Collection
/
BS1 part 05.zip
/
BS1 part 5
/
PDraw3.0.adf
/
pdraw_rex.lzh
/
AutoSave.pdrx
< prev
next >
Wrap
Text File
|
1992-06-18
|
1KB
|
49 lines
/*
@N
This Genie will prompt you to save at a specified time interval. You may optionally have the current file backed up before saving commences.
*/
cr = '0a'x
arg options
interval = word(options, 1)
backup = word(options, 2)
tval = getclip(pdautosave)
if tval = '' then
do
startas = 1
tval = 5
end
if ~exists("rexx:pdrawautosave.rexx") then
exit_msg("Unable to find PDraw autosave Genie in rexx: directory")
if interval = '' then
do
response = upper(pdm_GetForm("Enter time interval", 8, "Time interval in minutes:"tval||cr"Create backup file Y/N:Y"))
if response = '' then exit_msg()
parse var response tval '0a'x backup
if ~datatype(tval, n) | tval < 0 then exit_msg("Invalid Entry")
end
if backup ~= 'Y' then backup = 'N'
call setclip(pdautosave, tval)
if startas ~= 1 then exit
address command
'run >nil:' "rx rexx:pdrawautosave.rexx "backup
exit_msg()
exit_msg: procedure
do
parse arg message
if message ~= '' then
call pdm_Inform(1, message, )
exit
end